#ifndef QUERY_H
#define QUERY_H

#include <QStringList>
#include <QUrl>
#include <QTemporaryFile>

#include "plwordnetdao.h"
#include "tagger.h"

class Query
{
public:
    Query(const QString &filePath, const QStringList &stoplist, int resultNumber);
    Query(const QString &query, const QStringList &stoplist);
    QString getQuery() {return origQuery;}
    QUrl getQueryUrl();
    QString getQueryJson(QString &mid);
    QStringList getDocs() {return docs;}

private:
    void tagQuery();

    QString origQuery;
    QString query;
    QStringList docs;
    QStringList lexems;

    int resultNumber;

    static Tagger *tagger;
    static PlWordNetDAO wordnet;
};

#endif // QUERY_H
